<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>

    <style>
        div{
            width: 18.75rem;
            height: 18.75rem;
            border: .0625rem solid rebeccapurple;
            /* 渐变属性 支持多颜色渐变 至少两个值  支持方向   to right 
            to top right 
            
            支持角度  角度写法32deg
            */
            background: linear-gradient(30deg, red,green);

        }

    </style>

</head>
<body>
    <div></div>
</body>
</html>